import { loadPromptFromTemplate, generatePrompt } from '../loader.js';

interface DetailRecordProcessParams {
  implementationResults: string;
  recordingScope?: string[];
  evaluationFramework?: string[];
  knowledgeSharing?: boolean;
  documentationLevel?: string;
  memoryDir?: string;
}

export async function getDetailRecordProcessPrompt(params: DetailRecordProcessParams): Promise<string> {
  const template = await loadPromptFromTemplate('detailRecordProcess/index.md');
  
  return generatePrompt(template, {
    implementationResults: params.implementationResults,
    recordingScope: params.recordingScope?.join(', ') || 'decisions, implementations, tests, changes',
    evaluationFramework: params.evaluationFramework?.join(', ') || 'quantitative, qualitative',
    knowledgeSharing: params.knowledgeSharing ? '是' : '否',
    documentationLevel: params.documentationLevel || 'standard',
    memoryDir: params.memoryDir || ''
  });
}
